package com.topboya.linker.ui.adapter;

import android.content.Context;
import android.view.LayoutInflater;
import android.view.View;
import android.widget.TextView;

import com.topboya.linker.R;
import com.zhy.view.flowlayout.FlowLayout;
import com.zhy.view.flowlayout.TagAdapter;
import com.zhy.view.flowlayout.TagFlowLayout;

import java.util.List;

public class FlowdepTagAdapter extends TagAdapter<String> {
    private static final String TAG = "FlowdepTagAdapter:";
    private LayoutInflater  mLayoutInflater;
    private  TagFlowLayout flowLayout;
    private Context mContext;
    public FlowdepTagAdapter(Context mContext, TagFlowLayout flowLayout, List datas) {

        super(datas);
        mLayoutInflater = LayoutInflater.from(mContext);
        this.flowLayout =flowLayout;
        this.mContext = mContext;
    }

    @Override
    public View getView(FlowLayout parent, int position, String s) {


        View view =mLayoutInflater.inflate(R.layout.flow_layout,parent,false);
        TextView textView =view.findViewById(R.id.tv_departname);
        textView.setText(s);

        return view;
    }

}
